using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Drawing;
using System.Data;
using System.Text;
using System.Windows.Forms;
using DevExpress.XtraEditors;
using ProgramMain.Framework;

namespace ProgramMain.RecurringTariffPlans
{
    public partial class RecurringTariffEditorCtl : BaseDetailCtl
    {
        public RecurringTariffEditorCtl()
        {
            InitializeComponent();
        }

        public bool ShowQuantity
        {
            get { return recurringTariffListCtl1.ShowQuantity; }
            set
            {
                recurringTariffListCtl1.ShowQuantity = value;
            }
        }

        public bool EnableAddAction
        {
            get
            {
                return recurringTariffListCtl1.EnableAddAction;
            }
            set
            {
                recurringTariffListCtl1.EnableAddAction = value;
            }
        }

        public void HideRecurringAddDeleteOperations()
        {
            recurringTariffListCtl1.EnableAddAction = false;
        }

        private void RecurringTariffEditorCtl_DetailIDChanged(object sender, EventArgs e)
        {
            recurringTariffListCtl1.DetailID = this.DetailID;
        }
    }
}
